package functions

func input_text(name string, placeholder string) (out string) {
	out = input_basic(name, placeholder, "text")
	return
}

func input_label_text(label string, name string, placeholder string) (out string) {
	out = input_label_basic(label, name, placeholder, "text")
	return
}

func input_password(name string, placeholder string) (out string) {
	out = input_basic(name, placeholder, "password")
	return
}

func input_label_password(label string, name string, placeholder string) (out string) {
	out = input_label_basic(label, name, placeholder, "password")
	return
}

func input_label_basic(label string, name string, placeholder string, types string) (out string) {
	generatedId := "input" + StrFirstToUpper(name)
	out = "<div class=\"form-group\"><label for=\"" + generatedId + "\" class=\"col-lg-" + col_offset_width + " control-label\">" + label + "</label><div class=\"col-lg-" + col_lg_width + "\"><input name=\"" + name + "\" type=\"" + types + "\" class=\"form-control\" id=\"" + generatedId + "\" autocomplete=\"off\"></div></div>"
	return
}

func input_basic(name string, placeholder string, types string) (out string) {
	out = "<div class=\"form-group\"><input class=\"form-control\" placeholder=\"" + placeholder + "\" name=\"" + name + "\" type=\"" + types + "\" autocomplete=\"off\"></div>"
	return
}
